<?php
class User_Form_LoginForm extends Zend_Form
{
     public function init(){
        $this
            ->setMethod('post')
            ->setAttrib('id','frmLogin')
        ;

        $e = new Zend_Form_Element_Text('username');
        $e->setLabel('Username');
        $e->setRequired();
        $e->addValidator(new Zend_Validate_StringLength(array('min'=>5,'max'=>20)));
        $this->addElement($e);

        $e = new Zend_Form_Element_Password('password');
        $e->setRequired();
        $e->setLabel('Password');
        $this->addElement($e);

        //Submit
        $e = new Zend_Form_Element_Submit('submit');
        $e->setLabel('Login');
        $this->addElement($e);

    }


}
